<?php
/**
 * Created by PhpStorm.
 * User: liuchaozhong
 * Date: 2018/8/10
 * Time: 上午10:54
 */
namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class Member extends Model
{
    protected $table = 'member';

    protected $guarded = ['id','created_at'];
    //性别
    public $sex_arr = ['1'=>'男' ,'2'=>'女'];

    //关联任务记录
    public function g_task_config_log()
    {
        return $this->hasMany(TaskConfigLog::class, 'member_id');
    }

    //关联试玩任务
    public function g_task_test_log()
    {
        return $this->hasMany(DemoPlay::class, 'member_id');
    }

    //关联评论
    public function g_comment()
    {
        return $this->hasMany(Comments::class, 'member_id');
    }
}